import Vue from 'vue'
import Router from 'vue-router'
import Home from '@/components/Home'
import Login from '@/components/Login'
import Register from "@/components/Register"
import Course from "@/components/Course"
import Detail from "@/components/Detail"

Vue.use(Router);

export default new Router({
  mode: 'history',
  routes: [
    {
      path: '/',
      name: "Home",
      component: Home,
    },
    {
      name:"Home1",
      path: "/home",
      component:Home,
    },
    {
      name:"Login",
      path: "/login",
      component: Login,
    },
    {
      name:"Register",
      path: "/register",
      component: Register,
    },{
      name:"Course",
      path: "/courses",
      component: Course,
    },
    {
      name:"Detail",
      path: "/courses/:id",
      component: Detail,
    },
  ]
})
